import request from "../utils/request";

//查询的员工数据
export const queryEmpApi = (name,gender,begin,end,page,pageSize) => 
      request.get(`/emps?name=${name}&gender=${gender}&begin=${begin}&end=${end}&page=${page}&pageSize=${pageSize}`);

//新增员工
export const addEmpApi = (emp) => request.post('/emps',emp);
//查询回显
export let getByIdApi=(id)=>{return request.get(`/emps/${id}`)};
//修改员工信息
export let updateApi=(emp)=>{return request.put('/emps',emp)};
//批量删除员工
export let deleteByIdApi=(ids)=>{return request.delete(`/emps?ids=${ids}`)};